package com.itheima.table01;

import com.itheima.bean.Card;
import com.itheima.utils.MyBatisUtils;
import org.apache.ibatis.session.SqlSession;
import org.junit.Test;

import java.util.List;

public class Test01 {
    @Test
    public void findAll(){
        SqlSession sqlSession = MyBatisUtils.getSqlSession();
        OneToOneMapper mapper = sqlSession.getMapper(OneToOneMapper.class);
        List<Card> list = mapper.findAll();
        for (Card card : list) {
            System.out.println(card);
        }
        sqlSession.close();
    }
}
